<template>
	<view class="content">
		<view class="title">{{detail.title}}</view>
		<view class="sj">{{detail.creatTime}}</view>
		<view class="con" v-html="detail.content"></view>
	</view>
</template>

<script>
	import {
		getMessage
	} from '@/api/user.js'
	export default {
		data() {
			return {
				id: 0,
				detail: {}
			};
		},
		onLoad(options) {
			this.id = options.id
			this.init()
		},
		methods: {
			init() {
				getMessage({id: this.id}).then(res => {
					this.detail = res.data
				})
			},
		}
	}
</script>

<style lang="scss">
page {
	margin: 30rpx;
}
.content {
	width: calc(100% - 60rpx);
}
.title {
	font-size: 40rpx;
	text-align: center;
	margin-bottom: 30rpx;
}
.sj {
	font-size: 28rpx;
	color: #999;
	text-align: center;
}
.con {
	text-align: justify;
	line-height: 1.6;
}
</style>
